<div class="term-bar visible lazyloaded" data-bg="@Image" style="background-image: url('@Image');">
  <h1 class="term-title">@Name</h1></div>

<div class="site-content" style="padding-bottom: 60px;padding-top: 60px;">
  <div class="container">
  <div class="filter--content" style="@media (max-width: 768px) .filter--content{margin-top: -45px;}">
      <form class="mb-0" method="get" action="">
          <input type="hidden" name="s">
          <div class="form-box search-properties mb-0">
              <!-- 一级分类 -->
                          <div class="filter-item">

                  <ul class="filter-tag"><span><i class="fa fa-folder-open-o"></i> 分类</span>
@CateList_Start
    <li><a href="/List/@List_Id.html" class="id-@List_Id">@List_Name</a></li>
@CateList_End

  
  
  </ul>            </div>



                     <!-- 自定义筛选 -->
                                      <div class="filter-tab">
                  <div class="row">
                      <div class="col-12 col-sm-6">
                                              </div>
                      <div class="col-12 col-sm-6">
                          <!-- 排序 -->

                      </div>
                  </div>
              </div>

              <!-- .row end -->
          </div>
          <!-- .form-box end -->
      </form>
  </div>
  
  
  
  <div class="row">
    <div class="col-lg-12">
		<div class="content-area">
  			<main class="site-main">
  				<div class="row posts-wrapper">
  @Article_Start
  <div class="col-lg-1-5 col-6 col-sm-6 col-md-4 col-lg-3">
  <article id="post-@Id" class="post post-grid post-@Id type-post status-publish format-standard post-password-required hentry category-technology">
      <div class="entry-media">
    <div class="placeholder" style="padding-bottom: 66.666666666667%;">
      <a href="/Detail/@Id.html">
        <img class=" lazyloaded" data-src="@Thumb" src="@Thumb" alt="@Title">  
      </a>
          </div>
    <!--<div class="entry-format"><i class="fa fa-lock"></i></div>-->  </div>
      <div class="entry-wrapper">
            <a class="grid_author_avt" href="/Detail/@Id.html"><div class="grid_author_bggo avatar bg-cover" style="background-image: url(@AuthorImage);"></div> </a>
            
  <header class="entry-header">          <div class="entry-meta">
                 <span class="meta-category">
                          <a href="/List/@CateId.html" rel="category">
                  <i class="dot"></i>@CateName              </a>
                      </span>
              </div>
    
     <h2 class="entry-title"><a href="/Detail/@Id.html" title="@Title" rel="bookmark">@Title</a></h2>  </header>            <div class="entry-footer">
  <ul class="post-meta-box">

        <li class="meta-date">
      <time datetime="@Time"><i class="fa fa-clock-o"></i> @Time</time>
    </li>
            <li class="meta-views"><span><i class="fa fa-eye"></i> @Hits</span></li>
            <!--<li class="meta-comment"><span><i class="fa fa-comments-o"></i> 0</span></li>-->
                  
  </ul>
</div>    </div>
  </article>
</div>
  ,12
  @Article_End
  				</div>
              <div class="infinite-scroll-status">
                <div class="infinite-scroll-request"></div>
              </div>
  
  			  <div class="infinite-scroll-action">
                <div class="infinite-scroll-button button">加载更多</div>
              </div>
  			</main>
  		</div>
    </div>
  </div>
  
  
  
  
  </div>
</div>









<script>
  $(function(){
	var cid = "@Id";
	$(".id-"+cid).addClass("on");
    var eleCount = $(".posts-wrapper  .post-grid").length;
    
   	var limit = 12;
	var page = 2;
    if(limit>eleCount){
    	$(".infinite-scroll-button").css("display","none");
    }
	
	
	
	
	
	var template = `<div class='col-lg-1-5 col-6 col-sm-6 col-md-4 col-lg-3'>
  <article id='post-@Id' class='post post-grid post-@Id type-post status-publish format-standard post-password-required hentry category-technology tag-sspanel tag-v2ray'>
      <div class='entry-media'>
    <div class='placeholder' style='padding-bottom: 66.666666666667%;'>
      <a href='/Detail/@Id.html'>
        <img class=' lazyloaded' data-src='@Thumb' src='@Thumb' alt='@Title'> 
      </a>
          </div>
      </div>
      <div class='entry-wrapper'>
              <a class='grid_author_avt' href='/Detail/@Id.html'><div class='grid_author_bggo avatar bg-cover' style='background-image: url(@AuthorImage);'></div> </a>
            
  <header class='entry-header'>          <div class='entry-meta'>
                  <span class='meta-category'>
                          <a href='/List/@CateId.html' rel='category'>
                  <i class='dot'></i>@CateName              </a>
                      </span>
              </div>
    
    <h2 class='entry-title'><a href='/Detail/@Id.html' title='@Title' rel='bookmark'>@Title</a></h2>  </header>            <div class='entry-footer'>
  <ul class='post-meta-box'>

        <li class='meta-date'>
      <time datetime='@Time'><i class='fa fa-clock-o'></i> @Time</time>
    </li>
            <li class='meta-views'><span><i class='fa fa-eye'></i> @Hits</span></li>
            <!--<li class='meta-comment'><span><i class='fa fa-comments-o'></i> 0</span></li>-->
                  
  </ul>
</div>    </div>
  </article>
</div>`;
	
	
	
	$(".infinite-scroll-button").click(function(){
		$.get("/List/GetArticleInfo",{page:page,limit:limit,cateid:cid},function(res){
			for(var i = 0;i<res.length;i++){
				var data = template;
				data = data.replace(/@Title/g,res[i].title).replace(/@Id/g,res[i].id).replace(/@Thumb/g,res[i].thumb).replace(/@AuthorName/g,res[i].username).replace(/@AuthorImage/g,res[i].userImage).replace(/@CateName/g,res[i].cateName).replace(/@CateId/g,res[i].cateId).replace(/@Time/g,res[i].creatTime).replace(/@Hits/g,res[i].hits);
				$(".posts-wrapper").append(data);
			}
			if(res.length<limit){
				$(".infinite-scroll-button").css("display","none");
			}else{
				page++;
				$(".infinite-scroll-button").html("加载更多");
			}
		},"JSON");
		$(this).html("<i class='fa fa-spinner fa-spin'></i> 加载中...");
	});
  });
 </script>
